home *** CD-ROM | disk | FTP | other *** search
- /*
- * Raw (==HDLC) encoding of packet datagrams on an interface which can
- * do it. - mea@utu.fi OH1MQK 31-May-1992
- */
- #include "global.h"
- #include "mbuf.h"
- #include "proc.h"
- #include "iface.h"
- #include "internet.h"
- #include "ip.h"
- #include "slhc.h"
- #include "n8250.h"
- #include "asy.h"
- #include "pktdrvr.h"
- #include "socket.h"
- #include "devparam.h"
- #include "rawhdlc.h"
- #include "trace.h"
-
- /* Send IP datagram to HDLC -- that is, send to device output routine.. */
- int
- hdlc_send(bp,ifp,gateway,tos)
- struct mbuf *bp; /* Buffer to send */
- struct iface *ifp; /* Pointer to interface control block */
- int32 gateway; /* Ignored (HDLC is for point-to-point) */
- int tos;
- {
- return (*ifp->output)(ifp,NULLCHAR,NULLCHAR,0,bp);
- }
-
-
- /* Send a packet to HDLC -- that is, send to RAW device output routine.. */
- int
- hdlc_output(ifp,dest,source,protocol,data)
- struct iface *ifp; /* Pointer to interface control block */
- char *dest; /* Dest addr (ignored; point-to-point) */
- char *source; /* Source addr (ignored; point-to-point) */
- int16 protocol; /* Protocol Type field */
- struct mbuf *data; /* Actual data to be sent */
- {
- return (*ifp->raw)(ifp,data);
- }
-